/*
 * eclipseBinding.fx
 *
 * Created on 23-dic-2009, 20:22:07
 */

package ProgramSamples;

import javafx.stage.Stage;
import javafx.scene.Scene;
import javafx.scene.shape.Circle;
import javafx.scene.paint.Color;
import javafx.scene.paint.RadialGradient;
import javafx.scene.paint.Stop;
import javafx.scene.control.Slider;


Stage {
    title: "Data Binding"
    def slider = Slider {
            min: 0
            max: 60
            value : 50
            translateX: 10
            translateY: 110
    };
    scene: Scene {
	width: 220
	height: 170
	content: [ Circle {
            centerX: bind slider.value+50 centerY: 60 radius: 50
            stroke: Color.YELLOW
            fill: RadialGradient {
                centerX: 50 centerY : 60 radius: 50
                focusX: 50 focusY: 30
                proportional: false
                stops: [
                    Stop {offset: 0 color: Color.RED},
                    Stop {offset: 1 color: Color.WHITE}
                ]
             }//RadialGradient
        },//Circle
        slider
        ]
   }//Scene
}//Stage
